
package com.zhu.salesmanagement;

import com.dms2.salesmanagement.R;
import com.zhu.salesmanagement.provider.SalesSettings;

import android.app.Activity;
import android.database.Cursor;
import android.os.Bundle;
import android.view.View;
import android.view.Window;
import android.widget.TextView;

/**
 * 门店check重要讯息界面
 */

public class StoreScMsgActivity extends Activity implements View.OnClickListener {

    public static final String CUSTOMERID = "cid";
    public static final String IMSG = "msg";

    private String mCustomerId;
    private TextView mEditText = null;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        requestWindowFeature(Window.FEATURE_NO_TITLE);
        mCustomerId = getIntent().getStringExtra(CUSTOMERID);
        String msg = getIntent().getStringExtra(IMSG);
        setContentView(R.layout.layout_storescmsg_view);

        setupViews(msg);
    }

    private void setupViews(String msg) {
        mEditText = (TextView) findViewById(R.id.input_content);
        mEditText.setText(msg); 
        findViewById(R.id.input_back).setOnClickListener(this);
        findViewById(R.id.input_bottom_back).setOnClickListener(this);
    }

    @Override
    public void onClick(View arg0) {
        // TODO Auto-generated method stub
        if (arg0 != null) {
            switch (arg0.getId()) {
                case R.id.input_back:
                case R.id.input_bottom_back:
                    finish();
                    break;
            }
        }
    }
}
